package com.carlinfo.stu_ques.question.pojo;

import java.io.Serializable;
import java.util.Date;

import com.carlinfo.stu_ques.common.util.DateUtile;
import com.carlinfo.stu_ques.users.pojo.Grade;
import com.carlinfo.stu_ques.users.pojo.Students;

/**
 * 问题ID 学生ID 答案 对错  创建时间 修改时间
 * @author AcerMr
 *
 */
public class Answer implements Serializable
{
	private int id;/*ID*/
	private int questionId;
	private int sdId;/*学生ID*/
	private String answer;/*答案*/
	private String folg;/*对错*/
	private double level;/*成绩分数*/
	private Date createTime;/*创建时间*/
	private Date endTime;/*修改时间*/
	private Students student; /* 学生 */
	private Grade grade; /* 等级 */
	private Question question;/* 问题  */
	public void setId(int id)
	{
		this.id = id;
	}
	public int getId()
	{
		return this.id;
	}
	public int getSdId()
	{
		return sdId;
	}
	public void setSdId(int sdId)
	{
		this.sdId = sdId;
	}
	public String getAnswer()
	{
		return answer;
	}
	public void setAnswer(String answer)
	{
		this.answer = answer;
	}
	public String getFolg()
	{
		return folg;
	}
	public void setFolg(String folg)
	{
		this.folg = folg;
	}
	public Date getCreateTime()
	{
		return createTime;
	}
	public void setCreateTime(Date createTime)
	{
		this.createTime = createTime;
	}
	public Date getEndTime()
	{
		return endTime;
	}
	public void setEndTime(Date endTime)
	{
		this.endTime = endTime;
	}
	DateUtile dateUtil = new DateUtile();
	public String toString()
	{
		String result = getId()+"\t"+getSdId()+"\t"+getAnswer()+"\t"+getFolg()+"\t\t\t"+dateUtil.dateTimeToStr(getCreateTime())
				+"\t"+dateUtil.dateTimeToStr(getEndTime());
		return result;
	}
	public Students getStudent()
	{
		return student;
	}
	public void setStudent(Students student)
	{
		this.student = student;
	}
	public Grade getGrade()
	{
		return grade;
	}
	public void setGrade(Grade grade)
	{
		this.grade = grade;
	}
	public Question getQuestion()
	{
		return question;
	}
	public void setQuestion(Question question)
	{
		this.question = question;
	}
	public int getQuestionId()
	{
		return questionId;
	}
	public void setQuestionId(int questionId)
	{
		this.questionId = questionId;
	}
	public double getLevel()
	{
		return level;
	}
	public void setLevel(double level)
	{
		this.level = level;
	}	
}
